<!DOCTYPE html>
<html>
<head lang="en">
    <meta charset="UTF-8">
    <title></title>
    <style type="text/css">
        *{
            margin: 0;
            padding: 0;
        }
        ul {
            list-style: none;
        }
        .order-progress-wrapper {
            position: relative;
            padding: 32px 0;
            height: 90px;
        }
        .progress-bar {
            position: absolute;
            top: 32px;
            height: 8px;
            width: 80%;
            left: 10%;
            background: #ccc;
        }
        .progress-bar .progress-bar-inner {
            height: 8px;
            width: 0;
            background: #23b35a;
        }
        .step-list {
            position: absolute;
            top: 24px;
            width: 100%;
            height: 88px;
        }
        .step-list li {
            float: left;
            width: 20%;
            text-align: center;
            color: #333;
        }
        .step-list li span {
            display: inline-block;
            width: 24px;
            height: 24px;
            line-height: 24px;
            border-radius: 50%;
            background: #ccc;
            font-size: 14px;
            font-weight: bold;
            color: #fff;
        }
        .step-list li span.bg-change {
            background: #23b35a;
        }
        .step-list li p {
            padding-top: 8px;
        }
        .step-list li .step-name {
            font-size: 16px;
            font-weight: bold;
        }
        .step-list li .step-time {
            font-size: 14px;
        }
    </style>
</head>
<body>
    <div class="order-progress-wrapper">
        <div class="progress-bar">
            <div class="progress-bar-inner"></div>
        </div>
        <ul class="step-list">
            <li class="step1">
                <span class="step-number">1</span>
                <p class="step-name">提交订单</p>
                <p class="step-time">2017/05/04 21:47</p>
            </li>
            <li class="step2">
                <span class="step-number">2</span>
                <p class="step-name">接受订单</p>
                <p class="step-time">2017/05/04 21:47</p>
            </li>
            <li class="step3">
                <span class="step-number">3</span>
                <p class="step-name">已发货</p>
                <p class="step-time">2017/05/04 21:47</p>
            </li>
            <li class="step4">
                <span class="step-number">4</span>
                <p class="step-name">已签收</p>
                <p class="step-time">2017/05/04 21:47</p>
            </li>
            <li class="step5">
                <span class="step-number">5</span>
                <p class="step-name">订单完成</p>
                <p class="step-time">2017/05/04 21:47</p>
            </li>
            <br style="clear: both"/>
        </ul>
    </div>
    <script type="text/javascript" src="js/jquery.min.js"></script>
    <script type="text/javascript">
        $(function(){
            var stepCount = 4;
            var step = 0;
            var $progressBarInner = $(".progress-bar-inner");
            var stepNumbers = $(".step-number").get();
            function orderProgress(){
                if(step >= 4){
                    clearInterval(timer);
                }else{
                    $(stepNumbers[step]).addClass("bg-change");
                    step++;
                    $progressBarInner.animate({
                        "width": step * (1/stepCount * 100) + "%"
                    },500,function(){
                        $(stepNumbers[step]).addClass("bg-change");
                    });
                }
            }
            var timer = setInterval(orderProgress, 2000);
        });
    </script>
</body>
</html>